import api from '@/http/index'

class Api {
	/* 获取服务列表 */
	static getTablesList(data) {
		return new Promise((resolve, reject) => {
			api.get('/api/MedicalOrdersDTD/GetGridJson', data).then((res) => {
				resolve(res);
			}).catch(err => {
				reject(err)
			})
		});
	}
    /* 获取服务详情 */
    static getItemDetail(data) {
        return new Promise((resolve, reject) => {
            api.get('/api/MedicalOrdersDTD/GetOrderDetail', data).then((res) => {
                resolve(res);
            }).catch(err => {
                reject(err)
            })
        });
    }
    /* 订单确认 */
    static orderEdit(data) {
        return new Promise((resolve, reject) => {
            api.post('/api/MedicalOrdersDTD/OrderEdit', data).then((res) => {
                resolve(res);
            }).catch(err => {
                reject(err)
            })
        });
    }
    /* 获取门店 */
    static getShopTablesList = (data) => {
        return new Promise((resolve, reject) => {
            api.get('/api/Shop/GetGridJson', data).then((res) => {
                resolve(res);
            }).catch(err => {
                reject(err)
            })
        });
    };
}

export default Api


